package com.huanzhidadi.jsoup.entity;

import com.huanzhidadi.jsoup.annotation.Extract;
import com.huanzhidadi.jsoup.annotation.JsoupDocument;
import lombok.Data;

/**
 * 文章实体类
 */
@JsoupDocument(domain = "http://blog.huanzhidadi.com", targetUrl = "http://blog.huanzhidadi.com",
    cssQuery = ".article-box-content")
@Data
public class Article {

    @Extract(cssQuery = ".article-title > a")
    private String title;

    @Extract(cssQuery = ".article-title > a", attr = "href")
    private String url;

    /*@Extract(cssQuery = ".article-content")
    private String content;*/

    @JsoupDocument(domain = "http://blog.huanzhidadi.com", hrefAttr = "url")
    private ArticleContent articleContent;
}
